package com.sq.partner.manager.service.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.util.Assert;

import com.sq.partner.manager.dao.FacadeHisDao;
import com.sq.partner.manager.mybatis.model.FacadeHis;
import com.sq.partner.manager.service.FacadeHisService;
import com.sq.partner.manager.util.DateUtil;

/**
 * 保批单操作轨迹Service实现类
 * 
 * @author zhouxiuxiu
 *
 */
@Service
public class FacadeHisServiceImpl implements FacadeHisService {

    @Resource
    private FacadeHisDao facadeHisDao;

    @Override
    public FacadeHis saveFacadeHis(FacadeHis facadeHis) throws Exception {
        Assert.notNull(facadeHis.getSerialNumber());
        facadeHis.setCreatTime(DateUtil.getNowTimestamp());
        facadeHisDao.insertFacadeHis(facadeHis);
        return facadeHis;
    }
}
